//
//  ZMyHeaderCell.m
//  NewProject
//
//  Created by Apple on 2018/5/18.
//  Copyright © 2018年 chenIos. All rights reserved.
//

#import "ZMyHeaderCell.h"

@implementation ZMyHeaderCell
- (IBAction)clickButtonAction:(UIButton *)sender {
    self.clickBtn(sender);
}

- (void)awakeFromNib {
    [super awakeFromNib];
    for (UILabel *label in self.labels) {
        label.font = H4;
        label.textColor = [UIColor whiteColor];
    }

}
- (void)setItem:(NSDictionary *)item
{
    _item = item;
    NSArray *texts =  item[@"labelTexts"];
    for (int i = 0; i < texts.count; i++) {
        UILabel *label = self.labels[i];
        label.text = Z_Location(texts[i]);
    }
    
    NSArray *images = item[@"images"];
    for (int i = 0; i < images.count; i ++) {
        UIButton *btn = self.buttons[i];
        [btn setImage:[[UIImage imageNamed:images[i]] imageWithRenderingMode:(UIImageRenderingModeAlwaysOriginal)] forState:UIControlStateNormal];
         [btn setImage:[[UIImage imageNamed:images[i]]imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal] forState:UIControlStateSelected];
    }
}

@end
